#include<stdio.h>
#include<stdlib.h>
int main() {
    freopen("month.in","r",stdin);
    int y,m,day=-1;
    while(2==scanf("%d%d",&y,&m)) {
        day=-1;
        switch(m){
        case 1:case 3:case 5:case 7:case 8:case 10:case 12:
            day=31;
            break;
        case 4:case 6:case 9:case 11:
            day=30;
            break;
        case 2:
            day=(y%4==0&&y%100!=0||y%400==0)?29:28;
            break;
        }
        if(day>0)
            printf("%d\n",day);
        else
            puts("Are you kidding?");

    }

    return 0;
}
